home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Drivin' Route 66
/
Drivin' Route 66 (1995)(Creative Multimedia)[Mac-PC].iso
/
mac
/
RTMM.DIR
/
00011_Script_MAIN.other
< prev
next >
Wrap
Text File
|
1995-10-03
|
16KB
|
534 lines
--⌐ 1995, Cambridge Digital Media, Inc.
on pickState
put the frame into f
if f = 5 OR f = 7 OR (f > 11 AND f < 33) then
-- USA MAP:
repeat with s = 3 to 11
if rollOver(s) then
-- put line s-2 of field "state index" -- debug
put 1 into OnAState
exit repeat -- ???
else
put 0 into OnAState
end if
end repeat
if rollover(12) then
put 1 into OnAState
put 6 into s
end if
if OnAState then
put s-2 into BaseStateNum
go frame 11+(BaseStateNum*2)
if the mouseDown then -- GO TO A STATE:
-- SetupSigns
put s-2 into BaseStateNum
-- alert string(33+(BaseStateNum*2))
-- alert string((BaseStateNum))
if BaseStateNum = 9 then put 10 into BaseStateNum
updateStage
doDelay
prepMaps
repeat with s = 33 to 39
set the visible of sprite s to false
end repeat
go frame 33+(BaseStateNum*2)
end if
else
go frame 7
repeat with s = 35 to 37
puppetSprite s,0
if rollOver(s) then
puppetSprite s,1
set the castNum of sprite s to (the castNum of sprite s) + 1
updateStage
repeat while rollOver(s)
if the mouseDown then
set the castNum of sprite s to (the castNum of sprite s) + 1
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to (the castNum of sprite s) - 1
updateStage
doPicon s-34
updatestage
end if
end repeat
set the castNum of sprite s to (the castNum of sprite s) - 1
updateStage
puppetSprite s,0
put 1 into OnAPicon
else
put 0 into OnAPicon
end if
end repeat
end if
end if
go the frame
end
on pickSite -- Nice localized handler for state level
global currentStateMap,gtheState,gtheSite
if the visible of sprite 33 then -- TRIP PLANNER IS ON!!
nothing
else
hideTrip
put the frame into f
if f > 34 AND f < 55 then
repeat with s = 18 to 31 -- max number of signs
if rollOver(s) then
if the castnum of sprite s > 0 then
put 1 into OnASite
exit repeat -- ???
end if
else
put 0 into OnASite
end if
end repeat
if OnASite then
puppetSprite 17,1
-- Some rollOver() code for shield art:
put s - 18 into offsetSite -- ò18 = sprite 1 of shields...
put (findState() + offsetSite)*2 into goThisSite
put "U" & getPadded(goThisSite / 2) & "sm.PICT" into ShieldCastArt
-- put ShieldCastArt
set the castNum of sprite 17 to the number of cast ShieldCastArt
if the visible of sprite 17 = false then
set the visible of sprite 17 to true
end if
updateStage
put the frame-1 into currentStateMap
if the mouseDown then
set the castNum of sprite s to¼
(the number of cast "RTE 66 SITE BUTTON.h")
updatestage
-- RTE 66 SITE BUTTON.h
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to¼
(the number of cast "RTE 66 SITE BUTTON")
repeat with x = 1 to 46
puppetSprite x,0
end repeat
updatestage
prepSites
put findStateNumber() into gtheState
put -1 into gtheSite -- Always at top
put goThisSite + (61) -2 into foo
if foo > 179 then
go frame foo-2
else
go frame foo
end if
puppetPalette 0
-- yyy
PrimeNarrate
end if
else
if the visible of sprite 17 = true then
set the visible of sprite 17 to false
doDelay
end if
end if
-- TEST SIGNS ON STATE LEVEL:
repeat with s = 40 to 45
if rollOver(s) then
put 1 into OnASign
exit repeat -- ???
else
put 0 into OnASign
end if
end repeat
if OnASign then
if the mouseDown then
repeat with x = 40 to 45
puppetSprite x,1
end repeat
puppetTransition 0
updateStage
if s <> 44 then
set the castNum of sprite s to the castNum of sprite s+8
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to the castNum of sprite s-8
updateStage
end if
if s = 40 then -- U-TURN
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
go "US MAP"
else if s = 41 then -- HELP
helpScreen 1
else if s = 42 then -- 66
-- Skip 66 Shield...
else if s = 43 then -- EXIT
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
quit
else if s = 44 then -- L/R
put the locH of sprite s into midPt
if the mouseH < midPt then -- go back
set the castNum of sprite s to the castNum of sprite s-1
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to the castNum of sprite s+1
puppetSprite s,0
updateStage
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
if (the frame) - 1 = label("CA") then
-- CAN'T GO BACK MORE
else if (the frame) - 1 = label("TEX 2") then
go "NM"
else
go (the frame) - 3
end if
else -- go forth
set the castNum of sprite s to the castNum of sprite s+1
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
puppetSprite s,0
set the castNum of sprite s to the castNum of sprite s-1
updateStage
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
if (the frame) - 1 = label("ILL 1") then
-- CAN'T GO FURTHER
else if (the frame) - 1 = label("TEX 1") then
go "OK"
else
-- if the frame > 49 then
-- go "state 1"
-- else
go (the frame) + 1
-- end if
end if
end if
else if s = 45 then -- TRIPPY!
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
showTrip
end if
end if
end if
end if
end if
-- Should this go here?
go the frame
end
on clickSite -- Nice localized handler for state level
global currentStateMap,gtheState,gtheSite
if the visible of sprite 33 then -- TRIP PLANNER IS ON!!
nothing
else
put 1 into OnASite
if OnASite then
puppetSprite 17,1
-- Some rollOver() code for shield art:
repeat with s = 18 to 31 -- max number of signs
if rollOver(s) then
if the castnum of sprite s > 0 then
put 1 into OnASite
exit repeat -- ???
end if
else
put 0 into OnASite
end if
end repeat
put s - 18 into offsetSite -- ò18 = sprite 1 of shields...
put (findState() + offsetSite)*2 into goThisSite
put "U" & getPadded(goThisSite / 2) & "sm.PICT" into ShieldCastArt
-- put ShieldCastArt
set the castNum of sprite 17 to the number of cast ShieldCastArt
if the visible of sprite 17 = false then
set the visible of sprite 17 to true
end if
updateStage
put the frame-1 into currentStateMap
set the castNum of sprite s to¼
(the number of cast "RTE 66 SITE BUTTON.h")
updatestage
-- RTE 66 SITE BUTTON.h
repeat while the mouseDown
nothing
end repeat
doDelay
put 1 into OnASite
set the castNum of sprite s to¼
(the number of cast "RTE 66 SITE BUTTON")
repeat with x = 1 to 46
puppetSprite x,0
end repeat
updatestage
prepSites
put findStateNumber() into gtheState
put -1 into gtheSite -- Always at top
put goThisSite + (61) -2 into foo
if foo > 179 then
go frame foo-2
else
go frame foo
end if
puppetPalette 0
PrimeNarrate
else
end if
end if
end
on playSite
global currentStateMap,gTheState, where
go the frame
if the visible of sprite 33 then -- TRIP PLANNER IS ON!!
nothing -- nothing, baby
else
hideTrip
-- TEST SIGNS ON SITE LEVEL:
repeat with s = 40 to 45
if rollOver(s) AND (the visible of sprite s) then
put 1 into OnASign
exit repeat -- ???
else
put 0 into OnASign
end if
end repeat
if OnASign then
if the mouseDown then
repeat with x = 40 to 45
puppetSprite x,1
end repeat
puppetTransition 0
updateStage
if s <> 44 then
set the castNum of sprite s to the castNum of sprite s+8
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to the castNum of sprite s-8
updateStage
end if
if s = 40 then -- U-TURN
-- GO BACK TO THE RIGHT STATE!
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
prepMaps
go frame currentStateMap
else if s = 41 then -- HELP
helpScreen 1
else if s = 42 then -- 66
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
go "US MAP"
else if s = 43 then -- EXIT
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
quit
else if s = 44 then -- L/R
put the locH of sprite s into midPt
if the mouseH < midPt then -- go back
set the castNum of sprite s to the castNum of sprite s-1
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
set the castNum of sprite s to the castNum of sprite s+1
puppetSprite s,0
updateStage
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
-- DIRECTION SWITCHED 3/25/95 BT
-- No Special Case! Yay!
if (the frame) - 1 = label("site 65") then
go frame "site 1"
else
go frame (the frame) +1
end if
put GetCurrentState() into gTheState
PrimeNarrate
else -- go forth
set the castNum of sprite s to the castNum of sprite s+1
updateStage
repeat while the mouseDown
nothing
end repeat
doDelay
puppetSprite s,0
set the castNum of sprite s to the castNum of sprite s-1
updateStage
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
if (the frame) - 1 = label("site 1") then
go frame "site 65"
else
go frame (the frame) -3
end if
put GetCurrentState() into gTheState
PrimeNarrate
end if
else if s = 45 then -- TRIPPY!
repeat with x = 1 to 46
puppetSprite x,0
end repeat
puppetTransition 0
updateStage
showTrip
end if
end if
else
if the mouseDown then -- MAKE IT WORK LIKE CARMOD!!!
-- NEED TO SWITCH BUTTONS:
if the visible of sprite 14 then
-- Not Mode 3
if the visible of sprite 16 then
-- Mode 2:
-- Go to Mode 3:
puppetSound 0
updateStage
repeat with s = 14 to 16
set the visible of sprite s to false
end repeat
-- updateStage
go the frame -1
doDelay
else
-- Mode 1:
-- Go to Mode 2:
set the visible of sprite 16 to true
repeat with s = 40 to 45
set the visible of sprite s to false
end repeat
put the name of cast (the castNum of sprite 1) into here
delete char 1 of here
put integer(here) into test
--if test > 59 then
--put test - 1 into test
--put string(test) into here
--end if
put "RTU" & getPadded(here) & "TXA.AIF" into narrate
go the frame -1
doDelay
set the volume of sound 2 to 64
puppetSound 0
sound playfile 1, where & narrate
updateStage
end if
else
-- Mode 3:
-- Go to Mode 1:
puppetSound 0
updateStage
set the visible of sprite 14 to true
set the visible of sprite 15 to true
repeat with s = 40 to 45
set the visible of sprite s to true
end repeat
-- updateStage
go the frame -1
doDelay
end if
end if
end if
end if
-- Should this go here?
end
on primeNarrate
--alert "this is it!"
put the name of cast (the castNum of sprite 1) into here
delete char 1 of here
put integer(here) into test
if test > 59 then
put test - 1 into test
put string(test) into here
end if
put "RTU" & getPadded(here) & "TXA.AIF" into narrate
end